Integrand size = 23, antiderivative size = 121 \[ \int \frac {\cot ^7(c+d x)}{a+b \sin ^2(c+d x)} \, dx=-\frac {\left (3 a^2+3 a b+b^2\right ) \csc ^2(c+d x)}{2 a^3 d}+\frac {(3 a+b) \csc ^4(c+d x)}{4 a^2 d}-\frac {\csc ^6(c+d x)}{6 a d}-\frac {(a+b)^3 \log (\sin (c+d x))}{a^4 d}+\frac {(a+b)^3 \log \left (a+b \sin ^2(c+d x)\right )}{2 a^4 d} \]
-1/2*(3*a^2+3*a*b+b^2)*csc(d*x+c)^2/a^3/d+1/4*(3*a+b)*csc(d*x+c)^4/a^2/d-1 /6*csc(d*x+c)^6/a/d-(a+b)^3*ln(sin(d*x+c))/a^4/d+1/2*(a+b)^3*ln(a+b*sin(d* x+c)^2)/a^4/d
Time = 0.28 (sec) , antiderivative size = 100, normalized size of antiderivative = 0.83 \[ \int \frac {\cot ^7(c+d x)}{a+b \sin ^2(c+d x)} \, dx=-\frac {6 a \left (3 a^2+3 a b+b^2\right ) \csc ^2(c+d x)-3 a^2 (3 a+b) \csc ^4(c+d x)+2 a^3 \csc ^6(c+d x)+12 (a+b)^3 \log (\sin (c+d x))-6 (a+b)^3 \log \left (a+b \sin ^2(c+d x)\right )}{12 a^4 d} \]
-1/12*(6*a*(3*a^2 + 3*a*b + b^2)*Csc[c + d*x]^2 - 3*a^2*(3*a + b)*Csc[c + d*x]^4 + 2*a^3*Csc[c + d*x]^6 + 12*(a + b)^3*Log[Sin[c + d*x]] - 6*(a + b) ^3*Log[a + b*Sin[c + d*x]^2])/(a^4*d)
Time = 0.32 (sec) , antiderivative size = 110, normalized size of antiderivative = 0.91, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.174, Rules used = {3042, 3673, 99, 2009}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {\cot ^7(c+d x)}{a+b \sin ^2(c+d x)} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {1}{\tan (c+d x)^7 \left (a+b \sin (c+d x)^2\right )}dx\) |
\(\Big \downarrow \) 3673 |
\(\displaystyle \frac {\int \frac {\csc ^8(c+d x) \left (1-\sin ^2(c+d x)\right )^3}{b \sin ^2(c+d x)+a}d\sin ^2(c+d x)}{2 d}\) |
\(\Big \downarrow \) 99 |
\(\displaystyle \frac {\int \left (\frac {\csc ^8(c+d x)}{a}+\frac {(-3 a-b) \csc ^6(c+d x)}{a^2}+\frac {\left (3 a^2+3 b a+b^2\right ) \csc ^4(c+d x)}{a^3}-\frac {(a+b)^3 \csc ^2(c+d x)}{a^4}+\frac {b (a+b)^3}{a^4 \left (b \sin ^2(c+d x)+a\right )}\right )d\sin ^2(c+d x)}{2 d}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {-\frac {(a+b)^3 \log \left (\sin ^2(c+d x)\right )}{a^4}+\frac {(a+b)^3 \log \left (a+b \sin ^2(c+d x)\right )}{a^4}+\frac {(3 a+b) \csc ^4(c+d x)}{2 a^2}-\frac {\left (3 a^2+3 a b+b^2\right ) \csc ^2(c+d x)}{a^3}-\frac {\csc ^6(c+d x)}{3 a}}{2 d}\) |
(-(((3*a^2 + 3*a*b + b^2)*Csc[c + d*x]^2)/a^3) + ((3*a + b)*Csc[c + d*x]^4 )/(2*a^2) - Csc[c + d*x]^6/(3*a) - ((a + b)^3*Log[Sin[c + d*x]^2])/a^4 + ( (a + b)^3*Log[a + b*Sin[c + d*x]^2])/a^4)/(2*d)
3.5.48.3.1 Defintions of rubi rules used
Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_)*((e_.) + (f_.)*(x_) )^(p_), x_] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d*x)^n*(e + f*x)^p, x], x] /; FreeQ[{a, b, c, d, e, f, p}, x] && IntegersQ[m, n] && (IntegerQ[p] | | (GtQ[m, 0] && GeQ[n, -1]))
Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]^2)^(p_.)*tan[(e_.) + (f_.)*(x_)]^ (m_.), x_Symbol] :> With[{ff = FreeFactors[Sin[e + f*x]^2, x]}, Simp[ff^((m + 1)/2)/(2*f) Subst[Int[x^((m - 1)/2)*((a + b*ff*x)^p/(1 - ff*x)^((m + 1 )/2)), x], x, Sin[e + f*x]^2/ff], x]] /; FreeQ[{a, b, e, f, p}, x] && Integ erQ[(m - 1)/2]
Leaf count of result is larger than twice the leaf count of optimal. \(252\) vs. \(2(113)=226\).
Time = 7.28 (sec) , antiderivative size = 253, normalized size of antiderivative = 2.09
method | result | size |
derivativedivides | \(\frac {\frac {\left (a^{3}+3 a^{2} b +3 a \,b^{2}+b^{3}\right ) \ln \left (a +b -b \left (\cos ^{2}\left (d x +c \right )\right )\right )}{2 a^{4}}-\frac {1}{48 a \left (1+\cos \left (d x +c \right )\right )^{3}}-\frac {-5 a -2 b}{32 a^{2} \left (1+\cos \left (d x +c \right )\right )^{2}}-\frac {19 a^{2}+22 a b +8 b^{2}}{32 a^{3} \left (1+\cos \left (d x +c \right )\right )}+\frac {\left (-a^{3}-3 a^{2} b -3 a \,b^{2}-b^{3}\right ) \ln \left (1+\cos \left (d x +c \right )\right )}{2 a^{4}}+\frac {1}{48 a \left (\cos \left (d x +c \right )-1\right )^{3}}-\frac {-5 a -2 b}{32 a^{2} \left (\cos \left (d x +c \right )-1\right )^{2}}-\frac {-19 a^{2}-22 a b -8 b^{2}}{32 a^{3} \left (\cos \left (d x +c \right )-1\right )}+\frac {\left (-a^{3}-3 a^{2} b -3 a \,b^{2}-b^{3}\right ) \ln \left (\cos \left (d x +c \right )-1\right )}{2 a^{4}}}{d}\) | \(253\) |
default | \(\frac {\frac {\left (a^{3}+3 a^{2} b +3 a \,b^{2}+b^{3}\right ) \ln \left (a +b -b \left (\cos ^{2}\left (d x +c \right )\right )\right )}{2 a^{4}}-\frac {1}{48 a \left (1+\cos \left (d x +c \right )\right )^{3}}-\frac {-5 a -2 b}{32 a^{2} \left (1+\cos \left (d x +c \right )\right )^{2}}-\frac {19 a^{2}+22 a b +8 b^{2}}{32 a^{3} \left (1+\cos \left (d x +c \right )\right )}+\frac {\left (-a^{3}-3 a^{2} b -3 a \,b^{2}-b^{3}\right ) \ln \left (1+\cos \left (d x +c \right )\right )}{2 a^{4}}+\frac {1}{48 a \left (\cos \left (d x +c \right )-1\right )^{3}}-\frac {-5 a -2 b}{32 a^{2} \left (\cos \left (d x +c \right )-1\right )^{2}}-\frac {-19 a^{2}-22 a b -8 b^{2}}{32 a^{3} \left (\cos \left (d x +c \right )-1\right )}+\frac {\left (-a^{3}-3 a^{2} b -3 a \,b^{2}-b^{3}\right ) \ln \left (\cos \left (d x +c \right )-1\right )}{2 a^{4}}}{d}\) | \(253\) |
risch | \(\frac {6 a^{2} {\mathrm e}^{10 i \left (d x +c \right )}+6 a b \,{\mathrm e}^{10 i \left (d x +c \right )}+2 b^{2} {\mathrm e}^{10 i \left (d x +c \right )}-12 a^{2} {\mathrm e}^{8 i \left (d x +c \right )}-20 a b \,{\mathrm e}^{8 i \left (d x +c \right )}-8 b^{2} {\mathrm e}^{8 i \left (d x +c \right )}+\frac {68 a^{2} {\mathrm e}^{6 i \left (d x +c \right )}}{3}+28 a b \,{\mathrm e}^{6 i \left (d x +c \right )}+12 b^{2} {\mathrm e}^{6 i \left (d x +c \right )}-12 a^{2} {\mathrm e}^{4 i \left (d x +c \right )}-20 a b \,{\mathrm e}^{4 i \left (d x +c \right )}-8 b^{2} {\mathrm e}^{4 i \left (d x +c \right )}+6 a^{2} {\mathrm e}^{2 i \left (d x +c \right )}+6 a b \,{\mathrm e}^{2 i \left (d x +c \right )}+2 b^{2} {\mathrm e}^{2 i \left (d x +c \right )}}{d \,a^{3} \left ({\mathrm e}^{2 i \left (d x +c \right )}-1\right )^{6}}-\frac {\ln \left ({\mathrm e}^{2 i \left (d x +c \right )}-1\right )}{d a}-\frac {3 \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}-1\right ) b}{a^{2} d}-\frac {3 \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}-1\right ) b^{2}}{a^{3} d}-\frac {\ln \left ({\mathrm e}^{2 i \left (d x +c \right )}-1\right ) b^{3}}{a^{4} d}+\frac {\ln \left ({\mathrm e}^{4 i \left (d x +c \right )}-\frac {2 \left (2 a +b \right ) {\mathrm e}^{2 i \left (d x +c \right )}}{b}+1\right )}{2 a d}+\frac {3 \ln \left ({\mathrm e}^{4 i \left (d x +c \right )}-\frac {2 \left (2 a +b \right ) {\mathrm e}^{2 i \left (d x +c \right )}}{b}+1\right ) b}{2 a^{2} d}+\frac {3 \ln \left ({\mathrm e}^{4 i \left (d x +c \right )}-\frac {2 \left (2 a +b \right ) {\mathrm e}^{2 i \left (d x +c \right )}}{b}+1\right ) b^{2}}{2 a^{3} d}+\frac {\ln \left ({\mathrm e}^{4 i \left (d x +c \right )}-\frac {2 \left (2 a +b \right ) {\mathrm e}^{2 i \left (d x +c \right )}}{b}+1\right ) b^{3}}{2 a^{4} d}\) | \(479\) |
1/d*(1/2*(a^3+3*a^2*b+3*a*b^2+b^3)/a^4*ln(a+b-b*cos(d*x+c)^2)-1/48/a/(1+co s(d*x+c))^3-1/32*(-5*a-2*b)/a^2/(1+cos(d*x+c))^2-1/32*(19*a^2+22*a*b+8*b^2 )/a^3/(1+cos(d*x+c))+1/2*(-a^3-3*a^2*b-3*a*b^2-b^3)/a^4*ln(1+cos(d*x+c))+1 /48/a/(cos(d*x+c)-1)^3-1/32*(-5*a-2*b)/a^2/(cos(d*x+c)-1)^2-1/32*(-19*a^2- 22*a*b-8*b^2)/a^3/(cos(d*x+c)-1)+1/2*(-a^3-3*a^2*b-3*a*b^2-b^3)/a^4*ln(cos (d*x+c)-1))
Leaf count of result is larger than twice the leaf count of optimal. 371 vs. \(2 (113) = 226\).
Time = 0.40 (sec) , antiderivative size = 371, normalized size of antiderivative = 3.07 \[ \int \frac {\cot ^7(c+d x)}{a+b \sin ^2(c+d x)} \, dx=\frac {6 \, {\left (3 \, a^{3} + 3 \, a^{2} b + a b^{2}\right )} \cos \left (d x + c\right )^{4} + 11 \, a^{3} + 15 \, a^{2} b + 6 \, a b^{2} - 3 \, {\left (9 \, a^{3} + 11 \, a^{2} b + 4 \, a b^{2}\right )} \cos \left (d x + c\right )^{2} + 6 \, {\left ({\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \cos \left (d x + c\right )^{6} - 3 \, {\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \cos \left (d x + c\right )^{4} - a^{3} - 3 \, a^{2} b - 3 \, a b^{2} - b^{3} + 3 \, {\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \cos \left (d x + c\right )^{2}\right )} \log \left (-b \cos \left (d x + c\right )^{2} + a + b\right ) - 12 \, {\left ({\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \cos \left (d x + c\right )^{6} - 3 \, {\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \cos \left (d x + c\right )^{4} - a^{3} - 3 \, a^{2} b - 3 \, a b^{2} - b^{3} + 3 \, {\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \cos \left (d x + c\right )^{2}\right )} \log \left (\frac {1}{2} \, \sin \left (d x + c\right )\right )}{12 \, {\left (a^{4} d \cos \left (d x + c\right )^{6} - 3 \, a^{4} d \cos \left (d x + c\right )^{4} + 3 \, a^{4} d \cos \left (d x + c\right )^{2} - a^{4} d\right )}} \]
1/12*(6*(3*a^3 + 3*a^2*b + a*b^2)*cos(d*x + c)^4 + 11*a^3 + 15*a^2*b + 6*a *b^2 - 3*(9*a^3 + 11*a^2*b + 4*a*b^2)*cos(d*x + c)^2 + 6*((a^3 + 3*a^2*b + 3*a*b^2 + b^3)*cos(d*x + c)^6 - 3*(a^3 + 3*a^2*b + 3*a*b^2 + b^3)*cos(d*x + c)^4 - a^3 - 3*a^2*b - 3*a*b^2 - b^3 + 3*(a^3 + 3*a^2*b + 3*a*b^2 + b^3 )*cos(d*x + c)^2)*log(-b*cos(d*x + c)^2 + a + b) - 12*((a^3 + 3*a^2*b + 3* a*b^2 + b^3)*cos(d*x + c)^6 - 3*(a^3 + 3*a^2*b + 3*a*b^2 + b^3)*cos(d*x + c)^4 - a^3 - 3*a^2*b - 3*a*b^2 - b^3 + 3*(a^3 + 3*a^2*b + 3*a*b^2 + b^3)*c os(d*x + c)^2)*log(1/2*sin(d*x + c)))/(a^4*d*cos(d*x + c)^6 - 3*a^4*d*cos( d*x + c)^4 + 3*a^4*d*cos(d*x + c)^2 - a^4*d)
\[ \int \frac {\cot ^7(c+d x)}{a+b \sin ^2(c+d x)} \, dx=\int \frac {\cot ^{7}{\left (c + d x \right )}}{a + b \sin ^{2}{\left (c + d x \right )}}\, dx \]
Time = 0.21 (sec) , antiderivative size = 137, normalized size of antiderivative = 1.13 \[ \int \frac {\cot ^7(c+d x)}{a+b \sin ^2(c+d x)} \, dx=\frac {\frac {6 \, {\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \log \left (b \sin \left (d x + c\right )^{2} + a\right )}{a^{4}} - \frac {6 \, {\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \log \left (\sin \left (d x + c\right )^{2}\right )}{a^{4}} - \frac {6 \, {\left (3 \, a^{2} + 3 \, a b + b^{2}\right )} \sin \left (d x + c\right )^{4} - 3 \, {\left (3 \, a^{2} + a b\right )} \sin \left (d x + c\right )^{2} + 2 \, a^{2}}{a^{3} \sin \left (d x + c\right )^{6}}}{12 \, d} \]
1/12*(6*(a^3 + 3*a^2*b + 3*a*b^2 + b^3)*log(b*sin(d*x + c)^2 + a)/a^4 - 6* (a^3 + 3*a^2*b + 3*a*b^2 + b^3)*log(sin(d*x + c)^2)/a^4 - (6*(3*a^2 + 3*a* b + b^2)*sin(d*x + c)^4 - 3*(3*a^2 + a*b)*sin(d*x + c)^2 + 2*a^2)/(a^3*sin (d*x + c)^6))/d
Leaf count of result is larger than twice the leaf count of optimal. 353 vs. \(2 (113) = 226\).
Time = 0.45 (sec) , antiderivative size = 353, normalized size of antiderivative = 2.92 \[ \int \frac {\cot ^7(c+d x)}{a+b \sin ^2(c+d x)} \, dx=\frac {\frac {a^{2} {\left (\frac {\cos \left (d x + c\right ) + 1}{\cos \left (d x + c\right ) - 1} + \frac {\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1}\right )}^{3} + 12 \, a^{2} {\left (\frac {\cos \left (d x + c\right ) + 1}{\cos \left (d x + c\right ) - 1} + \frac {\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1}\right )}^{2} + 6 \, a b {\left (\frac {\cos \left (d x + c\right ) + 1}{\cos \left (d x + c\right ) - 1} + \frac {\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1}\right )}^{2} + 84 \, a^{2} {\left (\frac {\cos \left (d x + c\right ) + 1}{\cos \left (d x + c\right ) - 1} + \frac {\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1}\right )} + 120 \, a b {\left (\frac {\cos \left (d x + c\right ) + 1}{\cos \left (d x + c\right ) - 1} + \frac {\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1}\right )} + 48 \, b^{2} {\left (\frac {\cos \left (d x + c\right ) + 1}{\cos \left (d x + c\right ) - 1} + \frac {\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1}\right )}}{a^{3}} + \frac {192 \, {\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \log \left ({\left | -a {\left (\frac {\cos \left (d x + c\right ) + 1}{\cos \left (d x + c\right ) - 1} + \frac {\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1}\right )} + 2 \, a + 4 \, b \right |}\right )}{a^{4}}}{384 \, d} \]
1/384*((a^2*((cos(d*x + c) + 1)/(cos(d*x + c) - 1) + (cos(d*x + c) - 1)/(c os(d*x + c) + 1))^3 + 12*a^2*((cos(d*x + c) + 1)/(cos(d*x + c) - 1) + (cos (d*x + c) - 1)/(cos(d*x + c) + 1))^2 + 6*a*b*((cos(d*x + c) + 1)/(cos(d*x + c) - 1) + (cos(d*x + c) - 1)/(cos(d*x + c) + 1))^2 + 84*a^2*((cos(d*x + c) + 1)/(cos(d*x + c) - 1) + (cos(d*x + c) - 1)/(cos(d*x + c) + 1)) + 120* a*b*((cos(d*x + c) + 1)/(cos(d*x + c) - 1) + (cos(d*x + c) - 1)/(cos(d*x + c) + 1)) + 48*b^2*((cos(d*x + c) + 1)/(cos(d*x + c) - 1) + (cos(d*x + c) - 1)/(cos(d*x + c) + 1)))/a^3 + 192*(a^3 + 3*a^2*b + 3*a*b^2 + b^3)*log(ab s(-a*((cos(d*x + c) + 1)/(cos(d*x + c) - 1) + (cos(d*x + c) - 1)/(cos(d*x + c) + 1)) + 2*a + 4*b))/a^4)/d
Time = 13.95 (sec) , antiderivative size = 138, normalized size of antiderivative = 1.14 \[ \int \frac {\cot ^7(c+d x)}{a+b \sin ^2(c+d x)} \, dx=\frac {\ln \left (a+a\,{\mathrm {tan}\left (c+d\,x\right )}^2+b\,{\mathrm {tan}\left (c+d\,x\right )}^2\right )\,\left (a^3+3\,a^2\,b+3\,a\,b^2+b^3\right )}{2\,a^4\,d}-\frac {\frac {1}{6\,a}-\frac {{\mathrm {tan}\left (c+d\,x\right )}^2\,\left (a+b\right )}{4\,a^2}+\frac {{\mathrm {tan}\left (c+d\,x\right )}^4\,{\left (a+b\right )}^2}{2\,a^3}}{d\,{\mathrm {tan}\left (c+d\,x\right )}^6}-\frac {\ln \left (\mathrm {tan}\left (c+d\,x\right )\right )\,\left (a^3+3\,a^2\,b+3\,a\,b^2+b^3\right )}{a^4\,d} \]